package com.ProductionAndConsumption;

public class buyer implements Runnable{
    private Store2 store2;
    buyer(){};

    public buyer(Store2 store2) {
        this.store2 = store2;
    }

    @Override
    public void run() {
        try {
            Thread.sleep(500);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        store2.take();
    }
}
